<%@ page language="java" contentType="text/html; charset=UTF-8"
    pageEncoding="UTF-8"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<%@ taglib prefix="c"  uri="http://java.sun.com/jsp/jstl/core"%>
<%@ taglib prefix="fmt" uri="http://java.sun.com/jsp/jstl/fmt" %>
<%
	String path = request.getContextPath();
	String basePath = request.getScheme()+"://"+request.getServerName()+":"+request.getServerPort()+path+"/";
%>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>后台登录</title>
<meta name="author" content="DeathGhost" />
<link rel="stylesheet" type="text/css" href="css/style3.css" tppabs="css/style3.css" />
<style>
body{height:100%;background:#16a085;overflow:hidden;}
canvas{z-index:-1;position:absolute;}
</style>
<script src="js/jquery1.js"></script>
<script src="js/verificationNumbers1.js" tppabs="js/verificationNumbers1.js"></script>
<script src="js/Particleground1.js" tppabs="js/Particleground1.js"></script>
<!-- <script type="text/javascript" src="jquery1.8/jquery-1.8.0.min.js"></script> -->
<base href="<%=basePath%>">
<script>
	$(document).ready(function() {
	  //粒子背景特效
	  $('body').particleground({
	    dotColor: '#5cbdaa',
	    lineColor: '#5cbdaa'
	  });
	  //验证码
	  createCode();
	  //测试提交，对接程序删除即可
	//$(".submit_btn").click(function(){
	//	  location.href="javascrpt:;"/*tpa=http://***index.jsp*/;
	//	  });
	});
	$(function(){
		$("#login").click(function(){
			$.ajax({
				url:"<%=basePath%>AdminAction/adminLogin.do", 
				data:{"e_name":$("#e_name").val(),"e_pwd":$("#e_pwd").val()},
				type:"post",
				dataType:"json",
				success:function(data){
					if(data.miss){
							location.href="<%=basePath%>zhongzhuan.jsp";
					}else{
						$("#error").attr({"size":1,"color":"red"}).http("登录失败");
					}
				}
			});
		});
	});
</script>
</head>
<body>
<dl class="admin_login">
	 <dt>
		  <strong>好易贷后台管理系统</strong>
		  <em>Management System</em>
	 </dt>
	 <dd class="user_icon">
	  	<input type="text" placeholder="账号" class="login_txtbx" name="e_name" id="e_name" value="liufei"/><span id="error">&nbsp;</span>
	 </dd>
	 <dd class="pwd_icon">
	 	 	<input type="password" placeholder="密码" class="login_txtbx" name="e_pwd" id="e_pwd" value="123456"/>
	 </dd>
	 <dd class="val_icon">
	  	<div class="checkcode">
		    <input type="text" id="J_codetext" placeholder="验证码" maxlength="4" class="login_txtbx">
		    <canvas class="J_codeimg" id="myCanvas" onclick="createCode()">对不起，您的浏览器不支持canvas，请下载最新版浏览器!</canvas>
	 		 </div>
	  <input type="button" value="验证码核验" class="ver_btn" onClick="validate();">
	 </dd>
	 <dd>
	  	<!-- <input type="button" value="立即登陆" class="submit_btn" id="login" /> -->
	  	<button id="login" class="submit_btn">立即登陆</button>
	 </dd>
	 <dd>
  <p>© 深圳市好易贷金融有限公司  版权所有</p>
  <p>粤B383y780000</p>
 </dd>
</dl>
</body>
</html>
